package vip.sweet.biz.modular.cultural.service.impl;

import cn.hutool.core.bean.BeanUtil;
import cn.hutool.core.util.ObjectUtil;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;
import vip.sweet.biz.modular.cultural.entity.BizCulturalContent;
import vip.sweet.biz.modular.cultural.mapper.BizCulturalContentMapper;
import vip.sweet.biz.modular.cultural.params.BizCulturalContentAddParams;
import vip.sweet.biz.modular.cultural.service.BizCulturalContentService;

/**
 * @author ASUS
 * @Date 2025/10/4 23:53
 * @Descripition
 */
@Service
public class BizCulturalContentServiceImpl extends ServiceImpl<BizCulturalContentMapper, BizCulturalContent> implements BizCulturalContentService {
    @Override
    public boolean add(BizCulturalContentAddParams addCulturalContentParams) {
        if (ObjectUtil.isNotEmpty(addCulturalContentParams))
            return save(BeanUtil.toBean(addCulturalContentParams, BizCulturalContent.class));
        return false;
    }
}
